home *** CD-ROM | disk | FTP | other *** search
/ Mac Mania 1 / MacMania 1.toast / Hypercard / HyperCard' More / C-D / CheckWriter / Check Writer / card_4369.txt < prev    next >
Encoding:
Text File  |  1987-09-30  |  6.4 KB  |  293 lines

  1. -- card: 4369 from stack: in
  2. -- bmap block id: 5579
  3. -- flags: 4000
  4. -- background id: 3629
  5. -- name: 
  6.  
  7.  
  8. -- part 4 (button)
  9. -- low flags: 00
  10. -- high flags: A003
  11. -- rect: left=246 top=130 right=152 bottom=417
  12. -- title width / last selected line: 0
  13. -- icon id / first selected line: 0 / 0
  14. -- text alignment: 1
  15. -- font id: 0
  16. -- text size: 12
  17. -- style flags: 0
  18. -- line height: 16
  19. -- part name: Print Marked Checks
  20. ----- HyperTalk script -----
  21. on mouseUp
  22.   go to card "print"
  23. end mouseUp
  24.  
  25.  
  26.  
  27. -- part 6 (button)
  28. -- low flags: 00
  29. -- high flags: A003
  30. -- rect: left=19 top=211 right=233 bottom=205
  31. -- title width / last selected line: 0
  32. -- icon id / first selected line: 0 / 0
  33. -- text alignment: 1
  34. -- font id: 0
  35. -- text size: 12
  36. -- style flags: 0
  37. -- line height: 16
  38. -- part name: Change Printing Template
  39. ----- HyperTalk script -----
  40. on mouseUp
  41.   go to card "Template"
  42. end mouseUp
  43.  
  44.  
  45.  
  46.  
  47. -- part 7 (button)
  48. -- low flags: 00
  49. -- high flags: 2000
  50. -- rect: left=52 top=250 right=285 bottom=93
  51. -- title width / last selected line: 0
  52. -- icon id / first selected line: 20689 / 20689
  53. -- text alignment: 1
  54. -- font id: 0
  55. -- text size: 12
  56. -- style flags: 0
  57. -- line height: 16
  58. -- part name: Home
  59. ----- HyperTalk script -----
  60. on mouseUp
  61.   visual effect iris close
  62.   go home
  63. end mouseUp
  64.  
  65.  
  66.  
  67. -- part 8 (button)
  68. -- low flags: 00
  69. -- high flags: A000
  70. -- rect: left=177 top=249 right=294 bottom=235
  71. -- title width / last selected line: 0
  72. -- icon id / first selected line: 9301 / 9301
  73. -- text alignment: 1
  74. -- font id: 0
  75. -- text size: 12
  76. -- style flags: 0
  77. -- line height: 16
  78. -- part name: Last Check
  79. ----- HyperTalk script -----
  80. on mouseUp
  81.   visual effect barn door open
  82.   go to last card of bkgnd "Check"
  83. end mouseUp
  84.  
  85.  
  86. -- part 9 (button)
  87. -- low flags: 00
  88. -- high flags: A000
  89. -- rect: left=279 top=249 right=294 bottom=341
  90. -- title width / last selected line: 0
  91. -- icon id / first selected line: 27009 / 27009
  92. -- text alignment: 1
  93. -- font id: 0
  94. -- text size: 12
  95. -- style flags: 0
  96. -- line height: 16
  97. -- part name: First Check
  98. ----- HyperTalk script -----
  99. on mouseUp
  100.   visual effect barn door open
  101.   go to first card of bkgnd "Check"
  102. end mouseUp
  103.  
  104.  
  105. -- part 11 (button)
  106. -- low flags: 00
  107. -- high flags: A003
  108. -- rect: left=246 top=210 right=232 bottom=418
  109. -- title width / last selected line: 0
  110. -- icon id / first selected line: 0 / 0
  111. -- text alignment: 1
  112. -- font id: 0
  113. -- text size: 12
  114. -- style flags: 0
  115. -- line height: 16
  116. -- part name: Go to Check Register
  117. ----- HyperTalk script -----
  118. on mouseUp
  119.   go to stack "Check Register"
  120. end mouseUp
  121.  
  122.  
  123.  
  124.  
  125. -- part 12 (button)
  126. -- low flags: 00
  127. -- high flags: A003
  128. -- rect: left=246 top=184 right=206 bottom=418
  129. -- title width / last selected line: 0
  130. -- icon id / first selected line: 0 / 0
  131. -- text alignment: 1
  132. -- font id: 0
  133. -- text size: 12
  134. -- style flags: 0
  135. -- line height: 16
  136. -- part name: Clear All Print Buttons
  137. ----- HyperTalk script -----
  138. -- mouseUp -- Clear all the "print" boxes.
  139.  
  140. on mouseUp
  141.   set cursor to 4
  142.   repeat with i = (the number of first card of bkgnd "Check") to the number of cards
  143.     put false into background field  "Print" of card i
  144.   end repeat
  145. end mouseUp
  146.  
  147.  
  148.  
  149. -- part 13 (button)
  150. -- low flags: 00
  151. -- high flags: A003
  152. -- rect: left=246 top=157 right=179 bottom=417
  153. -- title width / last selected line: 0
  154. -- icon id / first selected line: 0 / 0
  155. -- text alignment: 1
  156. -- font id: 0
  157. -- text size: 12
  158. -- style flags: 0
  159. -- line height: 16
  160. -- part name: Update Check Register
  161. ----- HyperTalk script -----
  162. -- mouseUp -- Post all printed checks into the check register stack.
  163.  
  164. on mouseUp
  165.   global nbr,date,payTo,for,amount,saveRow
  166.   set lockScreen to true
  167.   go to first card of bkgnd "Check"
  168.   find word true in field "Print"
  169.   if the result is not empty then
  170.     answer "No marked checks."
  171.     go to first card
  172.     exit mouseUp
  173.   end if
  174.   put the number of this card into startNbr
  175.   ask "What is check number of the first check?"
  176.   if it is empty then exit mouseUp -- he cancelled
  177.   put it into nbr
  178.   set cursor to 4
  179.   put zero into count
  180.   put empty into saveRow
  181.   put short name of this stack into stk
  182.   push card
  183.   go to last card of stack "Check Register"
  184.   set lockScreen to false
  185.   set lockScreen to true
  186.   repeat
  187.     pop card
  188.     if field "Date" is not empty then put field "Date" & ", 19" & field "Year" into date
  189.     else put empty into date
  190.     put trim(field "Pay To") into payTo
  191.     put field "For" into for
  192.     put trim(field "Amount") into amount
  193.     push card
  194.     go to last card of stack "Check Register"
  195.     set lockScreen to false
  196.     send postCheck
  197.     set lockScreen to true
  198.     set numberFormat to "0"
  199.     add 1 to nbr
  200.     add 1 to count
  201.     pop card
  202.     go to next card of this bkgnd
  203.     find word true in field "Print"
  204.     if the number of this card is startNbr then exit repeat
  205.     push card
  206.   end repeat
  207.   pop card into it
  208.   go to stack "Check Writer"
  209.   set lockScreen to false
  210.   answer "All done ‚Äî " & count & " checks entered."
  211.   answer "Clear all print buttons?" with "Cancel" or "OK"
  212.   if it is "OK" then
  213.     send "mouseUp" to button "Clear All Print Buttons"
  214.   end if
  215. end mouseUp
  216.  
  217. -- trim -- Trim off all the asterisks before we post entries.
  218.  
  219. function trim s
  220. put s into t
  221. repeat -- trim off big chuncks of asterisks (for speed)
  222.   get offset("**********",t)
  223.   if it is 0 then exit repeat
  224.   delete char it to (it + 9) of t
  225. end repeat
  226. repeat -- trim the rest of 'em
  227.   get offset("*",t)
  228.   if it is 0 then exit repeat
  229.   delete char it of t
  230. end repeat
  231. return t
  232. end trim
  233.  
  234.  
  235.  
  236. -- part 14 (button)
  237. -- low flags: 00
  238. -- high flags: A003
  239. -- rect: left=32 top=182 right=204 bottom=195
  240. -- title width / last selected line: 0
  241. -- icon id / first selected line: 0 / 0
  242. -- text alignment: 1
  243. -- font id: 0
  244. -- text size: 12
  245. -- style flags: 0
  246. -- line height: 16
  247. -- part name: Sort Checks by Payee
  248. ----- HyperTalk script -----
  249. on mouseUp
  250.   sort by bkgnd field "Pay to"
  251. end mouseUp
  252.  
  253.  
  254.  
  255. -- part 17 (button)
  256. -- low flags: 00
  257. -- high flags: 0000
  258. -- rect: left=105 top=249 right=288 bottom=147
  259. -- title width / last selected line: 0
  260. -- icon id / first selected line: 2507 / 2507
  261. -- text alignment: 1
  262. -- font id: 0
  263. -- text size: 12
  264. -- style flags: 0
  265. -- line height: 16
  266. -- part name: Help
  267. ----- HyperTalk script -----
  268. on mouseUp
  269.   visual effect iris open
  270.   go to card "help"
  271. end mouseUp
  272.  
  273.  
  274. -- part 18 (button)
  275. -- low flags: 00
  276. -- high flags: 2000
  277. -- rect: left=9 top=141 right=174 bottom=216
  278. -- title width / last selected line: 0
  279. -- icon id / first selected line: 0 / 0
  280. -- text alignment: 1
  281. -- font id: 0
  282. -- text size: 12
  283. -- style flags: 0
  284. -- line height: 16
  285. -- part name: Shareware Info
  286. ----- HyperTalk script -----
  287. on mouseUp
  288.   visual effect iris open
  289.   go to card id 2465
  290. end mouseUp
  291.  
  292.  
  293.